Optimal. Leaf size=60 \[ \frac {(a+b x)^3 \left (a^2-b^2 x^2\right )^{1+p} \, _2F_1\left (1,5+2 p;5+p;\frac {a+b x}{2 a}\right )}{2 a b (4+p)} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.02, antiderivative size = 73, normalized size of antiderivative = 1.22, number of steps
used = 2, number of rules used = 2, integrand size = 22, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.091, Rules used = {692, 71}
\begin {gather*} -\frac {a^2 2^{p+3} \left (\frac {b x}{a}+1\right )^{-p-1} \left (a^2-b^2 x^2\right )^{p+1} \, _2F_1\left (-p-3,p+1;p+2;\frac {a-b x}{2 a}\right )}{b (p+1)} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 71
Rule 692
Rubi steps
\begin {align*} \int (a+b x)^3 \left (a^2-b^2 x^2\right )^p \, dx &=\left (a^2 (a-b x)^{-1-p} \left (1+\frac {b x}{a}\right )^{-1-p} \left (a^2-b^2 x^2\right )^{1+p}\right ) \int (a-b x)^p \left (1+\frac {b x}{a}\right )^{3+p} \, dx\\ &=-\frac {2^{3+p} a^2 \left (1+\frac {b x}{a}\right )^{-1-p} \left (a^2-b^2 x^2\right )^{1+p} \, _2F_1\left (-3-p,1+p;2+p;\frac {a-b x}{2 a}\right )}{b (1+p)}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] Leaf count is larger than twice the leaf count of optimal. \(155\) vs. \(2(60)=120\).
time = 0.31, size = 155, normalized size = 2.58 \begin {gather*} \frac {1}{2} \left (a^2-b^2 x^2\right )^p \left (\frac {\left (-a^2+b^2 x^2\right ) \left (a^2 (7+3 p)+b^2 (1+p) x^2\right )}{b (1+p) (2+p)}+2 a^3 x \left (1-\frac {b^2 x^2}{a^2}\right )^{-p} \, _2F_1\left (\frac {1}{2},-p;\frac {3}{2};\frac {b^2 x^2}{a^2}\right )+2 a b^2 x^3 \left (1-\frac {b^2 x^2}{a^2}\right )^{-p} \, _2F_1\left (\frac {3}{2},-p;\frac {5}{2};\frac {b^2 x^2}{a^2}\right )\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [F]
time = 0.12, size = 0, normalized size = 0.00 \[\int \left (b x +a \right )^{3} \left (-b^{2} x^{2}+a^{2}\right )^{p}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 348 vs.
\(2 (44) = 88\).
time = 2.33, size = 476, normalized size = 7.93 \begin {gather*} a^{3} a^{2 p} x {{}_{2}F_{1}\left (\begin {matrix} \frac {1}{2}, - p \\ \frac {3}{2} \end {matrix}\middle | {\frac {b^{2} x^{2} e^{2 i \pi }}{a^{2}}} \right )} + 3 a^{2} b \left (\begin {cases} \frac {x^{2} \left (a^{2}\right )^{p}}{2} & \text {for}\: b^{2} = 0 \\- \frac {\begin {cases} \frac {\left (a^{2} - b^{2} x^{2}\right )^{p + 1}}{p + 1} & \text {for}\: p \neq -1 \\\log {\left (a^{2} - b^{2} x^{2} \right )} & \text {otherwise} \end {cases}}{2 b^{2}} & \text {otherwise} \end {cases}\right ) + a a^{2 p} b^{2} x^{3} {{}_{2}F_{1}\left (\begin {matrix} \frac {3}{2}, - p \\ \frac {5}{2} \end {matrix}\middle | {\frac {b^{2} x^{2} e^{2 i \pi }}{a^{2}}} \right )} + b^{3} \left (\begin {cases} \frac {x^{4} \left (a^{2}\right )^{p}}{4} & \text {for}\: b = 0 \\- \frac {a^{2} \log {\left (- \frac {a}{b} + x \right )}}{- 2 a^{2} b^{4} + 2 b^{6} x^{2}} - \frac {a^{2} \log {\left (\frac {a}{b} + x \right )}}{- 2 a^{2} b^{4} + 2 b^{6} x^{2}} - \frac {a^{2}}{- 2 a^{2} b^{4} + 2 b^{6} x^{2}} + \frac {b^{2} x^{2} \log {\left (- \frac {a}{b} + x \right )}}{- 2 a^{2} b^{4} + 2 b^{6} x^{2}} + \frac {b^{2} x^{2} \log {\left (\frac {a}{b} + x \right )}}{- 2 a^{2} b^{4} + 2 b^{6} x^{2}} & \text {for}\: p = -2 \\- \frac {a^{2} \log {\left (- \frac {a}{b} + x \right )}}{2 b^{4}} - \frac {a^{2} \log {\left (\frac {a}{b} + x \right )}}{2 b^{4}} - \frac {x^{2}}{2 b^{2}} & \text {for}\: p = -1 \\- \frac {a^{4} \left (a^{2} - b^{2} x^{2}\right )^{p}}{2 b^{4} p^{2} + 6 b^{4} p + 4 b^{4}} - \frac {a^{2} b^{2} p x^{2} \left (a^{2} - b^{2} x^{2}\right )^{p}}{2 b^{4} p^{2} + 6 b^{4} p + 4 b^{4}} + \frac {b^{4} p x^{4} \left (a^{2} - b^{2} x^{2}\right )^{p}}{2 b^{4} p^{2} + 6 b^{4} p + 4 b^{4}} + \frac {b^{4} x^{4} \left (a^{2} - b^{2} x^{2}\right )^{p}}{2 b^{4} p^{2} + 6 b^{4} p + 4 b^{4}} & \text {otherwise} \end {cases}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} \int {\left (a^2-b^2\,x^2\right )}^p\,{\left (a+b\,x\right )}^3 \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________